package com.ipzoe.cms.enums;

public enum StartPageAppEnum {

    MICRO_APP(1, "小程序"), PC_WEB(2, "网站");

    private Integer code;
    private String info;

    StartPageAppEnum(Integer code, String info)
    {
        this.code = code;
        this.info = info;
    }

    public Integer getCode()
    {
        return code;
    }

    public String getInfo()
    {
        return info;
    }

    public static StartPageAppEnum getByCode(Integer key) {
        if (key == null) {
            return null;
        } else {
            for (StartPageAppEnum s : StartPageAppEnum.values()) {
                if (s.getCode().equals(key)) {
                    return s;
                }
            }
            return null;
        }
    }
}
